#!/usr/bin/env python3
# -*- Coding:UTF-8 -*-
#  14:10
from pprint import pprint

import yaml     #YAML文件的内容是兼容JSON文件的内容，即JSON的内容可以直接作为YAML文件的内容


class YamlTool(object):
    def __init__(self,path_):
        self.path=path_

    def reader(self):
        with open(self.path,encoding='UTF-8') as f:
            data=yaml.safe_load(f)
        return data

if __name__ == '__main__':
    d=YamlTool('../config/mysql_data.yaml').reader()
    pprint(d)
